//The triangle 2d class.
#ifndef TRI2D_H
#define TRI2D_H

#include "types.h"
#include "vec2d.h"

namespace ePhys {

	class tri2d
	{
	public:
		tri2d(void);
		tri2d(vec2d _p1, vec2d _p2, vec2d _p3);
		tri2d(tri2d *o);

		~tri2d(void);

		bool inTriangle(vec2d p);

		void set(tri2d &t) {
			p1 = t.p1;
			p2 = t.p2;
			p3 = t.p3;
		}

		vec2d p1, p2, p3;

	};

}

#endif
